#pragma once

#include <QWidget>
#include <Global.h>

namespace Domy {

class AbstractSettingsWidget : public QWidget
{
    Q_OBJECT
public:
    explicit AbstractSettingsWidget(QWidget *parent = Q_NULLPTR)
        : QWidget(parent), m_is_changed(false) {}
    ~AbstractSettingsWidget() {}

    virtual void apply() = 0;

    virtual void restoreDefault() = 0;

signals:
    void signalSettingsChanged();

protected slots:
    void slotOnSettingsChanged()
    {
        m_is_changed = true;

        emit signalSettingsChanged();
    }

protected:
    bool m_is_changed;
};

} // namespace Domy
